#include <stdio.h>
#include <unistd.h>
#include <stdlib.h>
#include "TcpServer.hpp"
int main(int argc, char *argv[])
{
    if (argc < 3)
    {
        printf("./a.out port path\n");
        return -1;
    }
    unsigned short port = atoi(argv[1]);//服务器启动后，端口才会使用
    //切换路径
    chdir(argv[2]);

    //启动服务器

    TcpServer* server = new TcpServer(port,4);
    server->run();
    return 0;
}